var proxy = require('../model_proxy');
var logger = require('../logger');
var updateImg = require('../updateImg');
var localFile = "/Users/qsym/Desktop/gui.jpg";
var mod = {
    index: function(req, res) {
        var Article = proxy.Article;
        updateImg(localFile, function(res) {
            console.log('resssss----', res);
        });
        Article.findAll(function(err, data) {
            console.log('err:::', err);
            console.log('data::::', data);
            res.render('index', {title: 'index', articles: data});
        });
        
    }
}

module.exports = mod;